﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Security.RightsManagement;
using System.Text;
using System.Threading.Tasks;

namespace Rainbow.model
{
    public class GlobalSettingViewModel : ViewModelBase
    {
        public GlobalSettingViewModel() { }

        public GlobalSettingViewModel(GlobalSetting setting)
        {
            this.rootPath = setting.rootPath;
            this.downloadThreadNum = setting.downloadThreadNum;
            this.uploadThreadNum = setting.uploadThreadNum;
        }

        private string m_rootPath;
        public string rootPath
        {
            get { return m_rootPath; }
            set
            {
                m_rootPath = value;
                NotifyPropertyChanged();
            }
        }

        private int m_downloadThreadNum;
        public int downloadThreadNum
        {
            get { return m_downloadThreadNum; }
            set
            {
                m_downloadThreadNum = value;
                NotifyPropertyChanged();
            }
        }

        private int m_uploadThreadNum;
        public int uploadThreadNum
        {
            get { return m_uploadThreadNum; }
            set
            {
                m_uploadThreadNum = value;
                NotifyPropertyChanged();
            }
        }
    }
}
